package com.work.filter;

import javax.servlet.*;
import java.io.IOException;
public class wrongcode implements Filter {
    public void init(FilterConfig filterConfig) throws ServletException {

    }

    public void doFilter(ServletRequest req, ServletResponse rep, FilterChain chain) throws IOException, ServletException {
     req.setCharacterEncoding("UTF-8");
     rep.setCharacterEncoding("UTF-8");
     rep.setContentType("text/html;charset=UTF-8");
     chain.doFilter(req,rep);
    }
    public void destroy() {

    }
}
